package com.laoxu.test.rbacdemo.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.laoxu.test.rbacdemo.common.PageRequest;
import com.laoxu.test.rbacdemo.model.SysRole;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author laoxu
 * @since 2020-08-09
 */
public interface SysRoleService extends IService<SysRole> {
    IPage<SysRole> findRoles(SysRole role, PageRequest request);

    List<SysRole> findUserRole(String userName);

    SysRole findByName(String roleName);

    void createRole(SysRole role);

    void deleteRoles(String[] roleIds) throws Exception;

    void updateRole(SysRole role) throws Exception;
}
